//
//  HJDViewController.m
//  weibo
//
//  Created by 胡金东 on 16/3/28.
//  Copyright © 2016年 胡金东. All rights reserved.
//

#import "HJDViewController.h"
#import "HJDTwoViewController.h"

@interface HJDViewController ()

@end

@implementation HJDViewController

-(void)viewWillAppear:(BOOL)animated
{
    [super viewWillAppear:animated];
    //隐藏导航栏
    self.navigationController.navigationBarHidden = NO;
    
}



- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
    UIButton *btn = [[UIButton alloc]initWithFrame:CGRectMake(100, 200, 100, 50)];
    [btn addTarget:self action:@selector(btnClick) forControlEvents:UIControlEventTouchUpInside];
    btn.backgroundColor = [UIColor redColor];
    [self.view addSubview:btn];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

-(void)btnClick
{
    HJDTwoViewController *TVC = [[HJDTwoViewController alloc]init];
    [self.navigationController pushViewController:TVC animated:YES];
}
@end
